import { handleActions } from 'redux-actions'

const init = {
  fields: []
};

export default handleActions({
  'reset system': (state) => ({
    ...state,
    ...init
  }),
  'fetch roster available fields': (state, { payload }) => ({
    ...state,
    fields: payload.profileFieldVOs
  })
}, init)
